README file for the replication archive for:

Christopher Adolph, Kenya Amano, Bree Bang-Jensen, 
Nancy Fullman, Beatrice Magistro, Grace Reinke, Rachel Castellano,Megan Erickson, and John Wilkerson. "The Pandemic Policy U-Turn:The role of partisanship, public health, and race in decisions
to ease COVID-19 social distancing policies in the U.S." 
Perspectives on Politics.

18 June 2021   cadolph@uw.edu

All analysis was done in R version 4.0.2.  Replication involves two parts:

(1) In the section labelled PROCESSING below, we list the files necessary to replicate the generation of the analysis dataset from the original sources.  

(2) In the section labelled ANALYSIS below, we list the files required to replicate the main results in the paper from a pre-processed analysis dataset.

Replicators can either follow the instructions for both sections or skip straight to replicating the analysis using the included analysis dataset. Required R packages are listed at the end of this file. 

PROCESSING: Replication of data processing to create the analysis dataset.  This step produces the Rdata file AnalysisData.Rdata used in the analysis replication step below.

Replicating the analysis dataset involves running this R script:
Processing.R

Helper script (must be in working directory):
HelperProcessing.R

Underlying datafiles (must be in /rawdata; see Processing.R for brief descriptions of each file and links to sources):
Council of State Governments Tourism data (2015).xlsx
COVIDdata.csv
Diffusion Neighboring States.csv
Ed Attainment, American Communities, 2017.csv
gbd2017_statepopest_2017.csv
GovernorPartyandTrumpVoteShare.xlsx
JobLessClaim.csv
KFF_GSP.csv
pop-urban-pct-historical.xls
pop_density.csv
PovertyRate.csv
RaceCensus2018.csv
Sales tax as % of state revenue from Urban Institute.csv
SPID_v1.0_network.csv
state party control 2020.xlsx
stateideology_v2018.dta
StatePolicy.csv

ANALYSIS: Replication of analytic results.  Replicators should run the 4 scripts listed below, which will output rough figures to the working directory in pdf format.  Note that the figures in the main text reflect additional stylistic polishing of these rough figures using Adobe Illustrator, and the tables were assembled by hand in Latex using the outputs of these scripts.

Main analysis dataset:
AnalysisData.Rdata

Codebook for main analysis dataset:
EasingCodebook.pdf

Script to produce Figures 2, 3, and 6 and contents of Table B1:
MainAnalysis.R

Script to produce Figure 4 and contents of Table B2:
DemGovAnalysis.R

Script to produce Figure 5 and contents of Table B3:
RepGovAnalysis.R

Script to produce Figure 1:
Figure1.R

Descriptive data for Figure 1 (see http://covid19statepolicy.org for variable definitions):
StatePolicy.csv

Helper functions for analysis scripts (must be in working directory):
HelperAnalysis.R

PACKAGES: Required R packages not in CRAN (install from disk before running the above scripts):

tile -- available from http://faculty.washington.edu/cadolph or from the included repositories in /packages:
tile_0.4.15.tar.gz    Sourcetile_0.4.15.tgz       Mactile_0.4.15.zip       PC

simcf -- available from http://faculty.washington.edu/cadolph or from the included repositories in /packages:
simcf_0.2.18.tar.gz   Sourcesimcf_0.2.18.tgz      Macsimcf_0.2.18.zip      PC

List of packages used from CRAN (with version numbers):
foreign         (0.8-80)
lubridate       (1.7.9)
readr           (1.3.1)
readstata13     (0.9.2)
readxl          (1.3.1)
stringr         (1.4.0)
tidyverse       (1.3.0)
aweek           (1.0.1)
survival        (3.1-12)
coxed           (0.3.3)
MASS            (7.3-51.6)
RColorBrewer    (1.1-2)
formula.tools   (1.7.1)
